package nccloud.web.pu.poorder.action;

import nc.itf.payapblebill.IPayableExtServer;
import nc.vo.pub.BusinessException;
import nccloud.dto.pu.poorder.entity.QueryInfo;
import nccloud.framework.service.ServiceLocator;
import nccloud.framework.web.action.itf.ICommonAction;
import nccloud.framework.web.container.IRequest;
import nccloud.framework.web.json.JsonFactory;

public class Sgyutiaction implements ICommonAction{

	@Override
	public Object doAction(IRequest request) {
		String read = request.read();
		QueryInfo info = (QueryInfo)JsonFactory.create().fromJson(read, QueryInfo.class);
		String[] pks = info.getPks();
		if (pks == null || pks.length == 0) {
			return null;
		}
		
		try {
			ServiceLocator.find(IPayableExtServer.class).prepayable(pks);
			
		} catch (BusinessException e) {
			e.printStackTrace();
		}
		
		return null;
	}

}
